package com.santiao.youxiang

import android.Manifest

object AppConst {
    const val CHANNEL = "OPPO" //CSJ  VIVO HUAWEI BAIDU OPPO BAIDU XIAOMI

    const val TAG = "ad_log"
    var isStopBoolen = false //判断是否隐藏图标
    var isSuspendedBoolen = true  //开启悬浮窗权限的时候 和开启系统权限
    const val Ad_ID = "5599762" //穿山甲广告APP ID
    const val GMCPAd_ID_IN = "103102648" //插屏应用内
    const val GMCPAd_ID_IN_TWO = "103103317" //插屏应用内2
    const val GMCPAd_THREE_ID_IN = "103103416" //插屏应用内 3
    const val FEEDSIMPLE_ID_ONE = "103103224" //信息流首页1
    const val FEEDSIMPLE_ID_TWO = "103101592" //信息流首页2
    const val FEEDSIMPLE_ID_THREE = "103103318" //信息流首页3
    const val GMSPAd_ID = "103103417" //开屏ID
    const val GMDDAd_ID = "889826752" //快报兜底开屏id
    const val GMSPAd_TWO_ID = "103102176" //开屏ID 2
    const val GMDDAd_TWO_ID = "889826754" //快报兜底开屏id 2
    const val GMRDAd_ID_IN = "103102456" //激励视频

    @JvmField
    var showAdHeadTitle = ""
    @JvmField
    var isLoadCpAd = false //因插屏展示率低，当点击功能，则进行缓存插屏广告，功能内展示插屏，则不需要在主页面进行展示
    var splashInfoShowMainCP = false

    @JvmField
    var isStopped = false
    @JvmField
    var riskInfo = ""
    @JvmField
    var AndroidId = ""
    //change CpuViewLoader.BD_APPSID
    const val UM_ID = "" //友盟
    @JvmField
    var is_ban_status = false //是否封禁
    var is_lockSwitch = false //锁屏信息流开关
    var is_motivationVideo = false //首次激励视频
    lateinit var BAIDU_APP_ID: String // 保存接口返回的baidu_appid

    const val BASE_URL = "https://api.dingjiwangluo.com"
    const val PATH_SEGMENTS_URL = "/dj-tools-api/" //PathSegments

    //    public static final String BASE_URL = "https://open.dingjiwangluo.com/"; //测试环境
    //    public static final String PATH_SEGMENTS_URL = "/clean_api/";//PathSegments 测试环境
    //0：信息流、1：全屏、2：插屏  用于ad_chain,click_trigge

    const val CHAPING = "chaping"
    const val QUANPING = "quanping"
    const val JILIVOID = "jilivoid"
    const val KAIPING = "kaiping"
    const val XINGXINLIU = "nat"
    const val INSTALL_FROM_APP = 1
    const val INSTALL_FROM_SPLASH = 2




    const val URL_USER_AGREEMENT =
        "https://app.xiaodanzi.com/protocol/mould/agreement/9e45e044-e8c7-4c9f-a21a-64fb57ba732c.html"//用户协议MK
    const val URL_PRIVACY_POLICY =
        "https://app.xiaodanzi.com/protocol/mould/privacy/9dfa3be5-29fc-47d0-957a-4e86b7062696.html";//隐私政策 MK

    var oaid = ""
    var is_show_ad = false //是否显示广告
    var is_curr_channel = "0" //当前安装渠道，0：自然量、1：巨量引擎、2：磁力引擎
    var is_adDelay = false
    var is_install = false //是否调用install接口了

    var DEVICE_OUT_NET_ID = "0.0.0.0"
    var DEVICE_OUT_NET_LOCATION = "0.0.0.0"
    const val IAPP_SCENE = "iapp"
    const val OAPP_SCENE = "oapp"
    var isPowerUninstalled = false //是否执行强力卸载
    var is_short = true //是否设置了强力卸载
    const val REPORT_TYPE_REQUEST = 2
    const val REPORT_TYPE_SHOW = 0
    const val REPORT_TYPE_CLICK = 1
    const val REPORT_TYPE_REQUEST_OK = 3

    var splashIsJumpMain = false


    @JvmField
    var isFront = false //判断首页是不是在前台

    var GetWebViewUserAgent = ""  //getWebViewUserAgent(instance) 因在install接口报错，所以提前进行获取
    /**
     * 要申请的权限字段
     */
    enum class PERMISSONURL constructor(val value: String, val errorMsg: String) {
        WRITE_EXTERNAL(
            Manifest.permission.WRITE_EXTERNAL_STORAGE,
            "你已拒绝存储权限，请在设置或安全中心里开启"
        ), // 写入权限
        READ_EXTERNAL(
            Manifest.permission.READ_EXTERNAL_STORAGE,
            "你已拒绝存储权限，请在设置或安全中心里开启"
        ), //读取权限
        READ_PHONE(
            Manifest.permission.READ_PHONE_STATE,
            "你已拒绝获取手机设备信息权限，请在设置或安全中心里开启"
        ), //获取设备号权限
        LOCATION(
            "android.permission.ACCESS_COARSE_LOCATION",
            "你已拒绝定位权限，请在设置或安全中心里开启"
        ), //摄像头权限
        FINE_LOCATION(
            Manifest.permission.ACCESS_FINE_LOCATION,
            "你已拒绝定位权限，请在设置或安全中心里开启"
        ), //摄像头权限
        CAMERA(Manifest.permission.CAMERA, "你已拒绝拍照权限，请在设置或安全中心里开启"), //摄像头权限
    }

}